package com.cskaoyan.javase.oop1._7exercise;

/**
 * 用面向对象的思想模拟LOL当中盖伦的战斗
 * 面向对象的思想编程,对象是程序的核心
 * 对象: 盖伦这个英雄
 * 类: 英雄类
 *
 * @since 11:15
 * @author wuguidong@cskaoyan.onaliyun.com
 */
public class Demo {
    public static void main(String[] args) {
        Legend galen = new Legend("galen", 1000, 0, "沉默", "护盾", "爱的魔力转圈圈", "大宝剑");
        galen.fight();
    }
}

class Legend {
    // 属性
    String name;
    int hp;
    int mp;
    String skillQ;
    String skillW;
    String skillE;
    String skillR;

    public Legend(String name, int hp, int mp, String skillQ, String skillW, String skillE, String skillR) {
        this.name = name;
        this.hp = hp;
        this.mp = mp;
        this.skillQ = skillQ;
        this.skillW = skillW;
        this.skillE = skillE;
        this.skillR = skillR;
    }

    // 行为
    public void fight() {
        System.out.println("英雄" + name + "正在释放" + skillR);
    }
}